package com.mhh.selary.backend.dto.api;

import com.mhh.sdk.beans.dto.BaseDTO;
import com.mhh.sdk.beans.dto.BaseItemDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import java.util.List;

/**
 * @author mhh
 * @date 2020-11-03 18:06:39
 */
@Getter
@Setter
@ApiModel("接口运行结果")
public class ApiHttpRunResultDTO extends BaseDTO {

    @ApiModelProperty(value = "请求url")
    private String requestUrl;

    @ApiModelProperty(value = "请求方法：GET/POST/...")
    private String method;

    @ApiModelProperty(value = "请求是否成功，即200")
    private boolean success;

    @ApiModelProperty(value = "http状态")
    private String httpStatus;

    @ApiModelProperty(value = "请求耗时")
    private Integer time;

    @ApiModelProperty(value = "响应数据大小")
    private Long size;

    @ApiModelProperty(value = "请求路径")
    private String urlPath;

    @ApiModelProperty(value = "协议版本")
    private String protocolVersion;

    @ApiModelProperty(value = "url请求参数")
    private String queryParam;

    @ApiModelProperty(value = "请求参数键值对")
    private List<BaseItemDTO> pairParam;

    @ApiModelProperty(value = "请求体参数")
    private String bodyParam;

    @ApiModelProperty(value = "请求头")
    private List<BaseItemDTO> requestHeaders;

    @ApiModelProperty(value = "响应头")
    private List<BaseItemDTO> responseHeaders;

    @ApiModelProperty(value = "响应内容")
    private String responseContent;


}
